#pragma once
#include "SceneAnimationTake.hxx"

namespace Eifersucht
{
	class SceneAnimationTake::Layer
	{
	public:

		struct ChannelCache; TinyTypeDecl(ChannelCache);
		typedef std::vector<ChannelCachePtr> ChannelCacheCollection; TinyTypeDecl(ChannelCacheCollection);

		REIGN_HINTINLINING void SetAt( _In_ uint32 index, _In_ ChannelCachePtr cache ) { m_vnChannels[index] = cache; }
		REIGN_HINTINLINING ChannelCachePtr GetAt( _In_ uint32 index ) { return m_vnChannels[index]; }
		REIGN_HINTINLINING void Push( _In_ ChannelCachePtr cache ) { m_vnChannels.push_back(cache); }
		REIGN_HINTINLINING ChannelCacheCollectionPtr Raw() { return &m_vnChannels; }
		REIGN_HINTINLINING uint32 Size() { return _To_uint m_vnChannels.size(); }

		REIGN_HINTINLINING ChannelCacheAddress GetAllFrom( _In_ uint32 index ) { return &m_vnChannels[index]; }
		REIGN_HINTINLINING ChannelCacheAddress GetAll() { return m_vnChannels.data(); }

		Layer();
		~Layer();

	private:

		ChannelCacheCollection m_vnChannels;

	};

	typedef SceneAnimationTake::Layer::ChannelCache SceneAnimationChannelCache;
};
